package com.lei2j.state;

import org.junit.Test;

/**
 * Created by lei2j on 2019/2/4.
 */
public class TestState {

    @Test
    public void test1(){
        GumballaMachine gumballaMachine = new GumballaMachine(5);
        System.out.println(gumballaMachine);
        gumballaMachine.insertQuarter();
        gumballaMachine.turnCrank();
        System.out.println(gumballaMachine);
        gumballaMachine.insertQuarter();
        gumballaMachine.ejectQuarter();
        System.out.println(gumballaMachine);
    }
}
